package com.netflexitysolutions.amazonws.sdb.orm;

import com.netflexitysolutions.amazonws.sdb.orm.metadata.ItemMetadata;

/**
 * @author netflexity
 *
 */
public interface SimpleDBSessionListener {

	/**
	 * @param <T>
	 * @param newRecord
	 * @param oldRecord
	 */
	public <T>void beforeSave(T newRecord, T oldRecord);
	
	/**
	 * @param <T>
	 * @param savedRecord
	 */
	public <T>void afterSave(T savedRecord);
	
	/**
	 * @param <T>
	 * @param record
	 */
	public <T>void beforeRemove(T record);
	
	/**
	 * @param <T>
	 * @param removedRecord
	 */
	public <T>void afterRemove(T removedRecord);
	
	/**
	 * @param <T>
	 * @param metadata
	 */
	public <T>void beforeSelect(ItemMetadata metadata);
	
	/**
	 * @param <T>
	 * @param record
	 */
	public <T>void initialize(T record);
}
